<?php
/**
 * +----------------------------------------------------------------------
 * | 佛祖保佑，永无bug！
 * +----------------------------------------------------------------------
 * | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
 * +----------------------------------------------------------------------
 * | Author: tudo<997470395@qq.com>2016/2/2411:41
 * +----------------------------------------------------------------------
 **/
namespace Home\Controller;

class CompanyController extends BaseController
{
    protected $m;

    public function __construct() {
        parent::__construct();
        $this->m = D("Company");
    }

    public function index() {
        $this->assign("company",$this->m-> getInfoByUid($this->userInfo['id']));
        $this->display();
    }

    public function auth() {
        $this->display();
    }

    //编辑基本的信息
    public function base() {
        $map['company_name'] = I('post.company_name', "");
        $map['intro'] = I('post.intro', "");
        $map['site_url'] = I("post.site_url", "");
        $map['uid'] = $this->userInfo['id'];
        $outPut = $this->m->addBase($map);
       $this->response($outPut, false);
    }
}